import { ApiProperty } from '@nestjs/swagger';
import { IsNotEmpty, IsString } from 'class-validator';

export class CreateDepartmentDto {
  @ApiProperty({ example: '1234567', description: '学院名称' })
  @IsString()
  @IsNotEmpty({ groups: ['create'], message: '学院名称' })
  name: string;

  @ApiProperty({ example: '1234567', description: '学院描述' })
  @IsString()
  desc: string;
}
